Skip to content

Copying MCAD CRDs in Kustomize config instead of referencing them #357

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 12 commits into from
Oct 20, 2023

Conversation

Fiona-Waters
Copy link
Contributor

Issue link

Closes #353

What changes have been made

Refactored to copy MCAD CRDs instead of referencing them.

Verification steps

  • Run make manifests and ensure that the config/crd/mcad/kustomization.yaml shows the mcad version (not 0.0.0.0).
  • Install MCAD in a cluster by running make install and ensure that the required CRDs have been created and that everything runs as expected.

Checks

  • I've made sure the tests are passing.
  • Testing Strategy
    • Unit tests
    • Manual tests
    • Testing is not required for this change

@openshift-ci
Copy link

openshift-ci bot commented Oct 19, 2023

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:
Once this PR has been reviewed and has the lgtm label, please assign maxusmusti for approval. For more information see the Kubernetes Code Review Process.

The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

Copy link
Contributor

@dimakis dimakis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm

@openshift-ci openshift-ci bot added the lgtm label Oct 20, 2023
@dimakis dimakis removed the lgtm label Oct 20, 2023
@Fiona-Waters Fiona-Waters force-pushed the mcad-crds branch 3 times, most recently from 138c2eb to 5eb6db6 Compare October 20, 2023 14:30
Makefile Outdated
.PHONY: check_yq
check_yq:
@command -v yq >/dev/null 2>&1 || (echo "Installing wget..."; yum install -y wget)
@command -v yq >/dev/null 2>&1 || (echo "Installing yq..."; wget https://github.com/mikefarah/yq/releases/download/v4.2.0/yq_linux_amd64.tar.gz -O - |\
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this needs to be YQ

Makefile Outdated

.PHONY: check_yq
check_yq:
@command -v yq >/dev/null 2>&1 || (echo "Installing wget..."; yum install -y wget)
Copy link
Contributor

@dimakis dimakis Oct 20, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this should be
@command -v wget

Makefile Outdated
process_sections:
@mkdir -p $(output_dir)
@for section_file in $(temp_dir)/section_*; do \
metadata_name=$$(yq e '.metadata.name' $$section_file); \
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Here you're calling YQ

@VanillaSpoon
Copy link
Contributor

If you check out this: https://github.com/actions/runner-images/blob/main/images/linux/Ubuntu2204-Readme.md

On ubuntu latest wget is preinstalled, and yum is not :)

Makefile Outdated
$(CONTROLLER_GEN) rbac:roleName=manager-role webhook paths="./..."
$(SED) -i -E "s|(- )\${MCAD_REPO}.*|\1\${MCAD_CRD}|" config/crd/mcad/kustomization.yaml
$(KUSTOMIZE) build config/crd/mcad > config/crd/mcad.yaml && make split_yaml FILE=config/crd/mcad.yaml
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

dont call this

Makefile Outdated
$(CONTROLLER_GEN) rbac:roleName=manager-role webhook paths="./..."
$(SED) -i -E "s|(- )\${MCAD_REPO}.*|\1\${MCAD_CRD}|" config/crd/mcad/kustomization.yaml
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

here too

@dimakis dimakis merged commit 4b863f7 into project-codeflare:main Oct 20, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Copy MCAD CRDs in Kustomize config instead of referencing them
5 participants